package dongshi.daddy.main;

import dongshi.daddy.service.MyProviderTokenService;
import org.springframework.context.support.ClassPathXmlApplicationContext;

public class ConsumerWithTokenMain {
    public static void main(String[] args) throws Exception {
        ClassPathXmlApplicationContext context
                = new ClassPathXmlApplicationContext("consumer-with-token.xml");
        context.start();
        MyProviderTokenService myProviderTokenService = (MyProviderTokenService) context.getBean("myProviderTokenServiceInConsumerSide");
        System.out.println(myProviderTokenService.sayHi("hello"));
        System.in.read();
    }

}
